var express = require("express");
var router = express.Router();
const Classify = require("../db/models/classify");
/* GET users listing. */
router.get("/", async function (req, res, next) {
  console.log("req:", req.query);

  //   res.send('respond with a resource');
  const ret = await Classify.findAll({
    where: {
      status: req.query.status || 1,
    },
  });
  res.send({
    code: 200,
    data: ret,
  });
  // next()
});

module.exports = router;
